From: Paul Eggert Date: Tue, 5 Apr 2011 20:08:03 +0000 (-0700) Subject: * sound.c (sound_warning): Don't crash if arg contains a printf format. X-Git-Tag: archive/raspbian/1%29.2+1-2+rpi1~1^2~324^2~4204^2~9 X-Git-Url: https://dgit.raspbian.org/%22http:/www.example.com/cgi/%22https:/www.github.com/%22bookmarks:///%22http:/www.example.com/cgi/%22https:/www.github.com/%22bookmarks:/?a=commitdiff_plain;h=6d488ca8a19260b7bec40ad33a4c6406dbf2041e;p=emacs.git * sound.c (sound_warning): Don't crash if arg contains a printf format. --- diff --git a/src/ChangeLog b/src/ChangeLog index c84999d69bc..950c10a0163 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -2,6 +2,8 @@ Fix more problems found by GCC 4.6.0's static checks. + * sound.c (sound_warning): Don't crash if arg contains a printf format. + * image.c (tiff_error_handler, tiff_warning_handler): Mark as printf-like functions. (tiff_load): Add casts to remove these marks before passing them diff --git a/src/sound.c b/src/sound.c index a2fe7ccc8ce..a972809e2c7 100644 --- a/src/sound.c +++ b/src/sound.c @@ -344,7 +344,7 @@ sound_perror (const char *msg) static void sound_warning (const char *msg) { - message (msg); + message ("%s", msg); }